<template>
	<view class="header" :style="{height: `${height}px`,'padding-top': `${top}px`}">
		<image src="../../static/images/home/header.png" mode="widthFix" style="width: 406rpx;"></image>
	</view>
</template>

<script>
	export default {
		data(){
			return {
				top: 20,
				height: 80
			}
		},
		created() {
			const system = wx.getSystemInfoSync()
			this.top = system.statusBarHeight
			const buttonInfo = wx.getMenuButtonBoundingClientRect()
			this.height = (buttonInfo.top - system.statusBarHeight)*2 + buttonInfo.height
			console.log(this.height)
			
		}
	}
</script>

<style scoped lang="scss">
	.header{
		width: 750rpx;
		display: flex;
		align-items: center;
		background-color: #F1F6FF;
	}
</style>